<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<div>
     承对人:<input type="text" id="seach">
    票面金额：<input type="text" id="money">
    逾期天数：<input type="text" id="day">
    服务金额<input type="text" id="cost">
    公司性质<input type="text" id="company_type">
    <button type="button" onclick="getlist()">搜索</button></div>
        <div id="box">

        </div>
</body>
</html>
　<script src="http://libs.baidu.com/jquery/2.1.4/jquery.min.js"></script>
<script>
    $(function(){
        $.ajax({
            url: "{:url('Order/getpageorderlist')}",
            data: {page:1,pagesax:20},
            type: "POST",
            dataType: "json",
            success: function(data) {
                var html = '';
                $.each(data.data, function (index, item) {
                    var url = "{:url('Orderbuy/getbuy')}?bill_no="+item.bill_no;
                    html +='id: '+item.id+'-----mc: '+item.bill_no+'名称：'+item.req_name+' status:'+item.status+'<a href="'+url+'"> 接单</a> <br>';
                });
                $("#box").append(html);
            }
        });
    });

    function  getlist(){
        var seach = $('#seach').val();
        var day = $('#day').val();
        var money = $('#money').val();
        var cost = $('#cost').val();
        var company_type = $('#company_type').val();
        $.ajax({
            url: "{:url('Order/getpageorderlist')}",
            data: {page:1,pagesax:20,seach:seach,day:day,money:money,cost:cost,company_type:company_type},
            type: "POST",
            dataType: "json",
            success: function(data) {
                $("#box").empty();
                var html = '';
                var url = "{:url('Orderbuy/getbuy')}";
                $.each(data.data, function (index, item) {
                    var url = "{:url('Orderbuy/getbuy')}?bill_no="+item.bill_no;
                    html +='id: '+item.id+'-----mc: '+item.bill_no+'名称：'+item.req_name+'票面金额：'+item.face_amt+'' +
                        ' status:'+item.status+'' +
                        ' days:'+item.days+'' +
                        ' sure_charge:'+item.sure_charge+'' +
                        '<a href="'+url+'"> 接单</a> <br>';
                });
                $("#box").append(html);
            }
        });
    }

</script>